package com.kang.service;

import com.kang.bean.*;
import com.kang.dto.UsersDto;
import com.kang.commons.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;

@FeignClient("springcloud-zuul") //调用的服务名称  spring。application。name的值
@RequestMapping("fawu/user-api/user")
@Service
public interface UsersService {

    @PostMapping
    Result<Users> getUsers2(String token);

    @PostMapping("public/login")
    Result login(@RequestBody UsersDto usersDto);


    @PostMapping("/update")
    Result updateUser(UsersDto usersDto);

    @GetMapping("/{id}")
    Result getUsersById(@PathVariable Long id);
}
